package ir;

public class DataInstruction {
	private String label;
	private int length;
	private String strVal;
	
	public DataInstruction(String label, int length, String strVal) {
		super();
		this.label = label;
		this.length = length;
		this.strVal = strVal.replaceAll("\\n", "\\\\n").replaceAll("\\t", "\\\\t").replaceAll("\\r", "\\\\r");
	}
	
	@Override
	public String toString(){
		return String.format(":%s\n\t%d\n\t\"%s\"\n", this.label, this.length, this.strVal);
	}
	
	
}
